import request from '@/utils/request'

// 获取宠物健康记录列表
export function getHealthRecords(petId) {
  return request({
    url: `/api/pets/${petId}/health-records`,
    method: 'get'
  })
}

// 创建健康记录
export function createHealthRecord(petId, data) {
  return request({
    url: `/api/pets/${petId}/health-records`,
    method: 'post',
    data
  })
}

// 更新健康记录
export function updateHealthRecord(petId, recordId, data) {
  return request({
    url: `/api/pets/${petId}/health-records/${recordId}`,
    method: 'put',
    data
  })
}

// 删除健康记录
export function deleteHealthRecord(petId, recordId) {
  return request({
    url: `/api/pets/${petId}/health-records/${recordId}`,
    method: 'delete'
  })
}